package org.eiahe.hr.attendance.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.ehe.common.mybatis.core.domain.BaseEntity;

import java.io.Serial;
import java.time.LocalDate;

/**
 * 特殊员工考勤规则对象 hr_special_attendance_rule
 *
 * @author zhangnn
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("hr_special_attendance_rule")
public class SpecialAttendanceRule extends BaseEntity {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 规则ID
     */
    @TableId(type = IdType.AUTO)
    private Long ruleId;

    /**
     * 工号
     */
    private String employeeNo;

    /**
     * 用户ID
     */
    private Long userId;

    /**
     * 规则内容描述
     */
    private String ruleContent;

    /**
     * 规则类型(如:哺乳期,病假等)
     */
    private String ruleType;

    /**
     * 容忍时长(分钟,如迟到容忍30分钟)
     */
    private Integer toleranceMinutes;

    /**
     * 生效日期
     */
    private LocalDate effectiveDate;

    /**
     * 失效日期
     */
    private LocalDate expiryDate;

    /**
     * 证明材料附件
     */
    private String attachment;

    /**
     * 审批状态(0-待审批 1-部门审批 2-人事审批 3-已通过 4-已拒绝)
     */
    private String approvalStatus;

    /**
     * 备注
     */
    private String remark;

    @TableLogic
    private String delFlag;
}
